Comparison operators in VectorScript are used to compare values of various types and return a Boolean value (true or false) result. The results of expressions using comparison operators are most often used to control the flow of script execution.
The < operator evaluates as
TRUE if the first operand is less than the second operand; otherwise it will evaluate as
FALSE. Operands may be numbers, strings, or characters; strings are evaluated alphabetically, by character encoding.
The <= operator evaluates as
TRUE if the first operand is less than or equal to the second operand; otherwise it will evaluate as
FALSE. Operands may be numbers, strings, or characters; strings are evaluated alphabetically, by character encoding.
The > operator evaluates as
TRUE if the first operand is greater than the second operand; otherwise it will evaluate as
FALSE. Operands may be numbers, strings, or characters; strings are evaluated alphabetically, by character encoding.
The >= operator evaluates as
TRUE if the first operand is greater than or equal to the second operand; otherwise it will evaluate as
FALSE. Operands may be numbers, strings, or characters; strings are evaluated alphabetically, by character encoding.
The = operator returns
TRUE if its two operands are exactly equal, and returns
FALSE if they are not equal. The operands may be of any type. For operands of type
STRING, the values are compared on a character-by-character basis, and must contain exactly the same characters.
The <> operator tests for the exact opposite of the
= operator. If two equal values are compared using the inequality operator, the resulting value will be
FALSE. Comparison of two values which are not equal will yield a
TRUE result.